import { axios } from '@/utils/request'

const api = {
  signjob: '/system/signjob'
}

export function getSysSignJobList (parameter) {
  return axios({
    url: api.signjob + '/list',
    method: 'get',
    params: parameter
  })
}

export function signJobStart (id) {
  return axios({
    url: api.signjob + `/start/${id}`,
    method: 'get'
  })
}

export function saveSysSignJob (parameter) {
  return axios({
    url: api.signjob + (parameter.id > 0 ? '/update' : '/save'),
    method: 'post',
    data: parameter,
    headers: {
      'Content-Type': 'application/json;charset=UTF-8'
    }
  })
}

export function delSysSignJob (parameter) {
  return axios({
    url: api.signjob + '/remove',
    method: 'post',
    params: parameter
  })
}

export const signjobExport = api.signjob + '/export'
